Reduce Indent of objects using DXL

Hi all,

how can I reduce the indent of all objects, that have a positive indent (from a word import)?
I tried the following code, which hasn't changed anything in my objects:
Object o
for o in current Module do{
o."Object Text" =richText( "\\li0" richTextFragment( richText( o."Object Text" ) ) )
}

Any ideas?

Thank you very much
Best Regards
Mathias Burchardt
Mathias_Burchardt - Fri Jul 09 10:36:31 EDT 2010

Re: Reduce Indent of objects using DXL
a_vestlin - Mon Jul 12 02:32:59 EDT 2010

Hi,

See 'string applyTextFormattingToParagraph(string s, bool addBullets, int indentLevel, int paraNumber)' in the DXL help.

/Anders

Re: Reduce Indent of objects using DXL
Mathias_Burchardt - Mon Jul 19 06:30:11 EDT 2010

a_vestlin - Mon Jul 12 02:32:59 EDT 2010
Hi,

See 'string applyTextFormattingToParagraph(string s, bool addBullets, int indentLevel, int paraNumber)' in the DXL help.

/Anders

Thank you very much, Anders, that did the trick.
My code now looks like that:

string s
RichTextParagraph rp
for o in current Module do {
s = richText o . "Object Text"
for rp in s do {
if (rp.indentLevel > 0) {
if (!containsOle(o."Object Text")){o."Object Text" = richText(applyTextFormattingToParagraph(s,false,0,0))}
}
}
}

Best Regards,
Mathias Burchardt